import React from "react";
import {LdhFieldSet} from "@biz/PageCompnents";
import {LdhFormItem, LdhInput, LdhInputNumber, LdhMapSelect, LdhObjListSelect} from "@biz/Components";
import BaseDetailPage from "@biz/BaseDetailPage";
import {createAction} from "../Action";
import Config from "../config";
import Store from "../Store";

const prefix = "config-detail";
export default class ConfigDetail extends BaseDetailPage {

    constructor(props) {
        super(props);
        this.action = createAction();
        this.config = Config(this.action);
        this.store = new Store(props, this.config, this.action);
        this.className = prefix;
    }



    renderDetail(isDetail) {
        let {loading} = this.state;
        return <LdhFieldSet title="基本信息" btn={!isDetail} loading={loading}>


            <LdhFormItem label="配置类别" name="groupCode" required isDetail={isDetail}>
                <LdhInput maxLength={64} showCount/>
            </LdhFormItem>
            <LdhFormItem label="配置编码" name="code" required isDetail={isDetail}>
                <LdhInput maxLength={64} showCount/>
            </LdhFormItem>
            <LdhFormItem label="配置名称" name="name" required isDetail={isDetail}>
                <LdhInput maxLength={64} showCount/>
            </LdhFormItem>
            <LdhFormItem label="配置值" name="value" required isDetail={isDetail}>
                <LdhInput maxLength={128} showCount/>
            </LdhFormItem>
            <LdhFormItem label="配置说明" name="desc" isDetail={isDetail}>
                <LdhInput maxLength={128} showCount/>
            </LdhFormItem>
            


        </LdhFieldSet>

    }
}